﻿Imports System
Imports System.Collections

Public Class GrupoBE
#Region "Campos y Propiedades"
    Private _IdGrupo As Integer
    Private _NombreGrupo As String
    Private _Estado As String
    Private _Tipo As String

    Public Property IdGrupo() As Integer
        Get
            Return _IdGrupo
        End Get
        Set(ByVal value As Integer)
            _IdGrupo = value
        End Set
    End Property

    Public Property NombreGrupo() As String
        Get
            Return _NombreGrupo
        End Get
        Set(ByVal value As String)
            _NombreGrupo = value
        End Set
    End Property

    Public Property Estado() As String
        Get
            Return _Estado
        End Get
        Set(ByVal value As String)
            _Estado = value
        End Set
    End Property

    Public Property Tipo() As String
        Get
            Return _Tipo
        End Get
        Set(ByVal value As String)
            _Tipo = value
        End Set
    End Property


#End Region

#Region "Constructores"

    Public Sub New()

    End Sub

    Public Sub New(ByVal IdGrupo As Integer, ByVal NombreGrupo As String, ByVal Estado As String, ByVal Tipo As String)
        Me._IdGrupo = IdGrupo
        Me._NombreGrupo = NombreGrupo
        Me._Estado = Estado
        Me._Tipo = Tipo
    End Sub
#End Region
End Class

Public Class GrupoBECollection
    Inherits CollectionBase

    Default Public Property Item(ByVal index As Integer) As GrupoBE
        Get
            Return CType(List(index), GrupoBE)
        End Get
        Set(ByVal value As GrupoBE)
            List(index) = value
        End Set
    End Property

    Public Function Add(ByVal value As GrupoBE) As Integer
        Return (List.Add(value))
    End Function

    Public Function IndexOf(ByVal value As GrupoBE) As Integer
        Return (List.IndexOf(value))
    End Function

    Public Sub Insert(ByVal index As Integer, ByVal value As GrupoBE)
        List.Insert(index, value)
    End Sub

    Public Sub Remove(ByVal value As GrupoBE)
        List.Remove(value)
    End Sub

    Public Function Contains(ByVal value As GrupoBE) As Boolean
        Return (List.Contains(value))
    End Function
End Class


